package com.sikaryofficial.backend.domain.mapping;

import com.sikaryofficial.backend.domain.dto.req.material.MaterialLibraryReq;
import com.sikaryofficial.backend.domain.dto.resp.materical.MaterialLibraryDTO;
import com.sikaryofficial.backend.domain.entity.Material;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

/**
 * @author : qinjinyuan
 * @desc : 活动映射接口
 * @date : 2023/11/03 9:19
 */
@Mapper
public interface MaterialLibraryMapping {
    MaterialLibraryMapping INSTANCE = Mappers.getMapper(MaterialLibraryMapping.class);

    /**
     * 实体映射resp
     *
     * @param activity
     * @return
     */
    MaterialLibraryDTO coverEntityToDTO(Material activity);

    /**
     * req映射实体
     *
     * @param activity
     * @return
     */
    Material coverReqToEntity(MaterialLibraryReq activity);
}
